{{ content() }}

<div class="page-content-area">
    <div class="page-header">
        <h1>
            Video group
        </h1>
        <div class="text-right">
            {{ link_to(config.application.backendUrl ~ "/video/group/create" , "<i class='ace-icon glyphicon glyphicon-plus bigger-120'></i> Them video group", "class": "btn btn-xs btn-primary") }}
        </div>
    </div>
    <div class="row">
        <div class="col-xs-12">
            <div class="row">
                <div class="col-xs-12">
                    <div class="dataTables_wrapper form-inline no-footer">
                        <div class="row">
                            <div class="col-xs-6"></div>
                            <div class="col-xs-6">
                                <div id="sample-table-2_filter" class="dataTables_filter">
                                    <label>
                                        Search:
                                        <input type="search" class="form-control input-sm" aria-controls="sample-table-2">
                                    </label>
                                </div>
                            </div>
                        </div>
                        <table class="table table-striped table-bordered table-hover dataTable no-footer">
                            <thead>
                            <tr>
                                <th>Id</th>
                                <th>name</th>
                                <th>Tổng số tập</th>
                                <th>Quốc gia</th>
                                <th>Năm sản xuất</th>
                                <th>Năm phát hành</th>
                                <th>Trạng thái</th>
                                <th>Hành động</th>
                            </tr>
                            </thead>
                            <tbody>
                            {% for group in pager %}
                                <tr>
                                    <td>{{ group.getId() }} </td>
                                    <td>
                                        {{ link_to(config.application.backendUrl ~ "/video/group/edit/" ~ group.getId() , group.getName() , "class": "btn btn-xs btn-info tooltip-success") }}
                                    </td>
                                    <td>{{ group.getTotalEpisode() }}</td>
                                    <td>{{ group.getNationalId() }}</td>
                                    <td>{{ group.getYearProduct() }}</td>
                                    <td>{{ group.getYearPublish() }}</td>
                                    <td>
                                        <span class="label label-sm label-success">
                                            {{ group.getStatus() }}
                                        </span>
                                    </td>
                                    <td>
                                        <div class="hidden-sm hidden-xs btn-group">
                                            {{ link_to(config.application.backendUrl ~ "/video/group/edit/" ~ group.getId() , "<i class='ace-icon fa fa-pencil bigger-120'></i>", "class": "btn btn-xs btn-info tooltip-success") }}
                                            {{ link_to(config.application.backendUrl ~ "/video/group/delete/" ~ group.getId(), "<i class='ace-icon fa fa-trash-o bigger-120'></i>","onclick=if(!confirm('Bạn có chắc xóa không?')){return false;};" , "class": "btn btn-xs btn-danger tooltip-success" ) }}
                                        </div>
                                    </td>
                                </tr>
                            {% endfor %}
                            </tbody>
                        </table>
                        <div class="row">
                            <div class="col-xs-6">
                                <div class="dataTables_info" id="sample-table-2_info" role="status" aria-live="polite">

                                </div>
                            </div>
                            <div class="col-xs-6">
                                {% if pager.haveToPaginate() %}
                                    {# Render the navigation #}
                                    {{ pager.getLayout() }}
                                {% endif %}
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>